#!/bin/bash
if [ -a ../fs.conf ] ; then
 source ../fs.conf
fi

# master squashfs location
SQUASHES_DIR="/mnt/gentoo-common/sources/stages4"
MASTER_SQUASH_FILE="nox-01.squash"
# realy used only that parameter
MASTER_SQUASH="$SQUASHES_DIR/$MASTER_SQUASH_FILE"


# real dirs
# workdir mountpoint
WORK_DIR="./work"
# workdir vs master.squash delta storage
WORK_DIR_DELTA="./diff.work"

# common non-root dir. My usage is portages tree + distfiles + homes
COMMON_DIR="/mnt/gentoo-common"
# common non-root dir delta storage
COMMON_DIR_DELTA="./diff.common"

# chrooted envinroment
# common non-root dir mountpoint = $WORK_DIR$COMMON_DIR_MOUNTPOINT
COMMON_DIR_MOUNTPOINT="/mnt/gentoo-common"
CHROOT_SHELL="/bin/bash"

# create dirs, if not exists
if     ! [ -d "$WORK_DIR" ] \
    || ! [ -d "$WORK_DIR_DELTA" ] \
    || ! [ -d "$COMMON_DIR_DELTA" ] ; then
    mkdir -p "$WORK_DIR"
    mkdir -p "$WORK_DIR_DELTA"
    mkdir -p "$COMMON_DIR_DELTA"
fi


